#include "calClient.hpp"
#include <memory>

using namespace std;
using namespace Client;

static void Usage(string proc)
{
    cout << "Usage:\n\t" << proc << " server_ip server_port\n\n";
}

int main(int argc, char *argv[])
{
    if (argc != 3)
    {
        Usage(argv[0]);
        exit(1);
    }

    uint16_t serverport = atoi(argv[2]);
    std::string serverip = argv[1];
    std::unique_ptr<tcpClient> tcli(new tcpClient(serverip, serverport));
    tcli->initClient();
    tcli->start();

    return 0;
}